package com.haotian.crc;

public class CRC32 {

	public String getCrc32Hex(byte[] data) {
		java.util.zip.CRC32 c = new java.util.zip.CRC32();
		c.update(data);
		return Long.toHexString(c.getValue());
	}

	public long getCtc32Long(byte[] data) {
		java.util.zip.CRC32 c = new java.util.zip.CRC32();
		c.update(data);
		return c.getValue();
	}

}
